package core;

import model.Bullet;
import model.Enemy;
import java.util.Random;

public class GameObjectFactory {
    // 创建敌人对象
    public static Enemy createEnemy() {
        int x = new Random().nextInt(400);
        int y = new Random().nextInt(300);
        return new Enemy(x, y);
    }

    // 创建子弹对象
    public static Bullet createBullet(int x, int y) {
        return new Bullet(x, y);
    }
}